<?php
   if($editselectorders->num_rows()>0): ?>
<?=form_open($this->uri->uri_string(),'enableservices'); ?>
<?php foreach ($editselectorders->result() as $row):?>

<table border="1px" width="400px" align="center">
<tr>
<td width="350px">
<?=$row->link_name ?>
</td>
<td>

<?php 
if($row->active=='true') $active = true ; else $active = false;
$data = array(
    'name'        => "services[$row->id]",
    'id'          => "services[$row->id]",
    'value'       => 'true',
	'checked'     => $active,
    );
   
 ?>
<?=form_checkbox($data) ?>
</td>
</tr>

<?php endforeach;?>
<?php endif; ?>
<tr>
<td colspan="2" align="center">
<input type="submit" name="submit" value="enable selected" />
</td></tr>
</table>
<?=form_close();?>